namespace Peninsula.DataAccess.EF.SqlServer.Migrations
{
    using System;
    using System.Data.Entity.Migrations;
    
    public partial class _004 : DbMigration
    {
        public override void Up()
        {
            CreateTable(
                "dbo.Households",
                c => new
                    {
                        Id = c.String(nullable: false, maxLength: 50),
                        UserName = c.String(nullable: false, maxLength: 50),
                        Password = c.String(nullable: false, maxLength: 100),
                        TrueName = c.String(nullable: false, maxLength: 50),
                        Phone = c.String(maxLength: 50),
                        Email = c.String(maxLength: 200),
                        Sex = c.Byte(nullable: false),
                        FaceImgPath = c.String(maxLength: 500),
                        FailedPasswordAttemptCount = c.Int(nullable: false),
                        IsLockedOut = c.Boolean(nullable: false),
                        LastLockoutDate = c.DateTime(),
                        LastLoginDate = c.DateTime(),
                        BuldiingsNum = c.Int(nullable: false),
                        LayersNum = c.Int(nullable: false),
                        Numbering = c.Int(nullable: false),
                        IsDeleted = c.Boolean(nullable: false),
                        CreatedTime = c.DateTime(nullable: false),
                        UpdatedTime = c.DateTime(),
                        UpdatedBy = c.String(nullable: false, maxLength: 50),
                        CreatedBy = c.String(nullable: false, maxLength: 50),
                    })
                .PrimaryKey(t => t.Id);
            
        }
        
        public override void Down()
        {
            DropTable("dbo.Households");
        }
    }
}
